/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.ejb.metier;

import com.ejb.persistence.Order;
import com.ejb.persistence.OrderState;
import java.util.HashMap;
import java.util.List;
import javax.ejb.Local;

/**
 *
 * @author Adel Boukelt
 * Class used to manage orders
 * 
 */
@Local
public interface IOrderManager {

    public boolean addOrder(Long idUser, HashMap<Long,Integer> listBook);


    public boolean setState(Long idUser,OrderState state);

    public List<Order> getOrders(Long idUser, boolean waiting);
    
    public List<Order> getOrdersByUserAndStates(long idUser, OrderState state);
    
    public List<Order> getOrdersByUserAndTwoStates(long idUser, OrderState state1, OrderState  state2);
    
}
